package com.c5p1ng.cloudmall.coupon.feign;

import com.c5p1ng.cloudmall.coupon.entity.CouponHistoryEntity;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import java.util.List;

@FeignClient("cloudmall-coupon")
@RequestMapping("/feign/coupon")
public interface CouponFeignService {
    /**
     * 获取会员优惠券
     * @return
     */
    @RequestMapping(value = "/member/list/{memberId}", method = RequestMethod.GET)
    public List<CouponHistoryEntity> getMemberCoupons(@PathVariable("memberId") Long memberId);
}
